<template>
  <div class="showConceptList">
    <ul class="conceptImg">
      <div class="theImg" :style="'background:url('+info.img_src+');background-size:cover;background-position:center;background-repeat:no-repeat;height:'+imgHeight+'px'"></div>
    </ul>
    <div class="content" :style="'width:'+(imgWidth-20)+'px'">
      <ul>
        <li class="title">{{(this.lang==='cn')?info.title:info.title_en}}</li>
        <li class="line" :style="'width:'+(imgWidth/12)+'px'"></li>
        <li class="subContent">{{(this.lang==='cn')?info.content:info.content_en}}</li>
      </ul>
    </div>
  </div>
</template>

<script>
    export default {
        name: "brandStoryContent",
      methods:{
        getImgWidth(){
          this.imgHeight=200;
          this.imgWidth=document.body.clientWidth;
        }
      },
      computed:{
        lang:{
          get(){
            let storageData = window.sessionStorage.getItem('lang');
            if(this.$store.state.lang!==storageData&&storageData!=='null'){
              this.$store.dispatch('toChangeLang', storageData);    //同步操作
            }
            return this.$store.getters.getLang;
          },
          set(){}
        },
      },
      data(){
        return{
          imgHeight:0,
          imgWidth:0,
        }
      },
      props:{
        info:{},
      },
      created(){
        this.getImgWidth()
      }
    }
</script>

<style scoped>
  .showConceptList{
    position: relative;
    box-sizing: border-box;
  }
  .conceptImg{
    width:100%;
    height:auto;
    font-size: 0;
    background: #000;
  }
  .conceptImg .theImg{
    display: block;
    z-index: 10;
    opacity: 0.5;
    background-size:auto 130%
  }
  .content{
    position:absolute;
    color:#FFF;
    top: 50%;
    transform: translate(0, -50%);
  }
  .content ul{
    width:100%;
  }
  .content .title{
    font-size:15px;
  }
  .content .line{
    background: #FFF;
    height: 0;
    border-top: solid #ACC0D8 1px;
    display: inline-block;
    margin-bottom:5px;
  }
  .content .subContent{
    font-size: 12px;
    font-weight: lighter;
    padding-right: 10px;
    padding-left: 10px;
  }
  .fill{
    position: absolute;
    width:10px;
    height:200px;
    margin-top: 0px;
    margin-right: -10px;
    z-index: 2500;
    background: #f5f5f5;
    opacity:1;
    right:0;
  }
  .fill:after{
    clear: both;
  }
</style>
